Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

texconv: add --ignore-srgb, --wic-uncompressed and revisit --wic-lossless #555

Merged
merged 3 commits into from
Nov 13, 2024

Conversation

walbourn
Copy link
Member

@walbourn walbourn commented Nov 12, 2024

  • Adds --ignore-srgb switch which passes TGA_FLAGS_IGNORE_SRGB or WIC_FLAGS_IGNORE_SRGB to the loader as appropriate.

  • Adds --wic-uncompressed switch which applies to TIFF and HEIF.

  • --wic-lossless should not be applied to JPEG as it only has a quality setting. This switch now only applies JPEG XR.

  • Add --wic-quality handling for HEIF codec output.

  • Remove heic as an option for output as the extension can read both, but only supports writing hief.

@walbourn walbourn added the tools Applies to texconv, texdiag, texassemble, etc. label Nov 12, 2024
@walbourn walbourn changed the title texconv: add -ignore-srgb and fix -wic-lossless for JPG texconv: add --ignore-srgb and revisit --wic-lossless Nov 12, 2024
@walbourn
Copy link
Member Author

In my initial implementation of these switches, I was basing it on the 'general principle' that WIC has ImageQuality is between 0 and 1, and 1 means "lossless if you support it".

In practice over time, the tool only sets these on specific codecs so this has resulted in consumer confusion. In addition, I've conflated "no compression" with "lossless" in the case of TIFF.

This PR tries to straighten all that out.

@walbourn walbourn changed the title texconv: add --ignore-srgb and revisit --wic-lossless texconv: add --ignore-srgb, --wic-uncompressed and revisit --wic-lossless Nov 12, 2024
@walbourn
Copy link
Member Author

@walbourn walbourn merged commit 2b6f585 into main Nov 13, 2024
100 checks passed
@walbourn walbourn deleted the texconvflags branch November 13, 2024 04:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tools Applies to texconv, texdiag, texassemble, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Texconv --ignore-colorspace Texconv: is WIC JPEG quality 1.0 actually lossless
2 participants